<?php
namespace Admin\Controller;
use Think\Controller;

class BaseController extends Controller {
	/**
	 * 检测登录
	 * @return [type] [description]
	 */
    public function _initialize(){
        //设置字符集
        header("Content-Type:text/html; charset=utf-8");
        $sid = session('adminId');
        //判断用户是否登陆
        if(!isset($sid ) ) {
            redirect(U('Login/index'));
        }

    }
    

}